During belief propagation low-density parity-check decoding, trapping sets (messages that are close to codewords but that cannot be decoded by a decoder) could appear. It is possible to enumerate all trapping sets of a given code, and for each trapping set compute distortions which each trapping set introduces to a message.
It is possible to enumerate all trapping sets violating only one or two parity check constraints because the number of such trapping sets is limited. However, the number of trapping sets rapidly grows as the number of violated constraints increases (i.e. size of a trapping set) and such listing technique cannot be directly applied if the number of violated constraints is relatively high (greater than three).
Consequently, it would be advantageous if an apparatus existed that is suitable for post-processing a low-density parity-check encoded message to provide a valid codeword in all cases.